package com.sservice.web.controller.common;


import com.sservice.base.entity.dto.BaseResult;
import com.sservice.web.common.util.net.HttpRequest;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by suweiming on 2019/1/24.
 */
@Controller
@RequestMapping("http")
public class Http {

    @RequestMapping(value = "get", method = RequestMethod.POST)
    @ResponseBody
    public BaseResult get(String param,String url) {
        return new BaseResult(true,HttpRequest.doGet(url,param),200);
    }
}
